import numpy as np
import os
import pickle

address = os.path.join('ntu_Normalization_13','xview')
lableFileName = 'val_label.pkl';
l = os.listdir(address);
l1 = []
for i in l:
    if 'train_raw_data' in i:
       l1.append(i)

data = np.load(os.path.join(address,l1[0]))
print(data.shape)
with open(os.path.join(address,lableFileName),'rb') as fr:
    label = pickle.load(fr)
label = np.array(label)
l = []
for i in range(18932):
    trainData = np.load(os.path.join(address,l1[i]))
    oneLabel = label[1][i]
    l.append((trainData,oneLabel))
np.save('ntu_data.npy',l)